import base from "./base";
import axios from "@/utils/request";

const api = {
  totalInfo() {
    return axios.get(base.totalInfo);
  },
  orderinfo() {
    return axios.get(base.orderinfo);
  },
  format() {
    return axios.get(base.format);
  },
  projectList(params) {
    return axios.get(base.projectList, { params });
  },
  search(params) {
    return axios.get(base.search, { params });
  },
  deleteItemById(params) {
    return axios.get(base.deleteItemById, { params });
  },
  selectItemCategoryByParentId(params) {
    return axios.get(base.selectItemCategoryByParentId, { params });
  },
  insertTbItem(params) {
    return axios.get(base.insertTbItem, { params });
  },
  batchDelete(params) {
    return axios.get(base.batchDelete, { params });
  },
  updateTbItem(params) {
    return axios.get(base.updateTbItem, { params });
  },
  itemCategory() {
    return axios.get(base.itemCategory);
  },
  insertItemCategory(params) {
    return axios.get(base.insertItemCategory, { params });
  },
  deleteContentCategoryById(params) {
    return axios.get(base.deleteContentCategoryById, { params });
  },
  updateCategory(params) {
    return axios.get(base.updateCategory, { params });
  },
  insertCategory(params) {
    return axios.get(base.insertCategory, { params });
  },
  orderList(params) {
    return axios.get(base.orderList, { params });
  },
  changeStatus(params) {
    return axios.get(base.changeStatus, { params });
  },
  collect(params) {
    return axios.get(base.collect, { params });
  },
  cancel(params) {
    return axios.get(base.cancel, { params });
  },
  getDetail(params) {
    return axios.get(base.detail, { params });
  },
  login(params) {
    return axios.post(base.login, params);
  },
  permission(params) {
    return axios.get(base.permission, { params });
  },
};

export function permission(params) {
  return axios.get(base.permission, { params });
}

export default api;
